package top.canyue.eca_manager.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;
import top.canyue.eca_manager.bean.Result;
import top.canyue.eca_manager.service.LogService;

@RestController
@RequestMapping(value = "/api/log")
public class LogController {
    @Autowired
    private LogService logService;

    @RequestMapping(value = "/getLoginTrendByWeek", method = RequestMethod.GET)
    public Result getLoginTrendByWeek() {
        return logService.getLoginTrendByWeek();
    }

    @RequestMapping(value = "/getSystemStability", method = RequestMethod.GET)
    public Result getSystemStability() {
        return logService.getSystemStability();
    }
}
